Skip to content

Fix unsafe recommended calver release expression#3231

Merged
wlthomson merged 5 commits into
mainfrom
wlthomson/fix-versioning-example-docs
Jul 3, 2026
Merged

Fix unsafe recommended calver release expression#3231
wlthomson merged 5 commits into
mainfrom
wlthomson/fix-versioning-example-docs

Conversation

@wlthomson

@wlthomson wlthomson commented Jul 3, 2026

Copy link
Copy Markdown
Contributor

Fixes the example complex release expression and adds a warning callout to signpost users towards using the alternative mask-based expression for generating calver release versions.

The removed expression (#{if Octopus.Date.Day==Octopus.Version.LastPatch}...) behaves unexpectedly when comparisons include single-digit days and months. This is due to formatting differences between Octopus.Date.Day/Month and Octopus.Version.LastPatch/LastMinor, with the former being zero-padded and the latter not. This causes the equality check to always fail when matching against dates containing single-digit days or months, causing releases to collide on the same version number instead of incrementing. This has been reported by multiple customers and replicated internally.

@wlthomson wlthomson requested a review from a team July 3, 2026 02:19
@team-marketing-branch-protections

Copy link
Copy Markdown

Pull request environment is available at https://stoctodocspr3231.z22.web.core.windows.net.

You can view the ephemeral environment status in Octopus Deploy.

This environment will be automatically deprovisioned when the pull request is closed, or after 7 days of inactivity.

@wlthomson wlthomson enabled auto-merge (squash) July 3, 2026 05:40
@wlthomson wlthomson disabled auto-merge July 3, 2026 05:40
@wlthomson wlthomson changed the title Remove unsafe recommended calver release expression Fix unsafe recommended calver release expression Jul 3, 2026
@wlthomson wlthomson enabled auto-merge (squash) July 3, 2026 05:46
@wlthomson wlthomson merged commit f411d05 into main Jul 3, 2026
7 checks passed
@wlthomson wlthomson deleted the wlthomson/fix-versioning-example-docs branch July 3, 2026 05:55
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants